import { defineStore } from "pinia"
import { getEquipmentIds } from '@/api/equipment'
export const UseEquipements = defineStore({
    id: 'Equipements',
    state: () => ({
        ids: [],
        idlist: []
    }),
    actions: {
        async getIds(code) {
            const res = await getEquipmentIds(code)
            this.$patch({
                ids: res.data.toString(),
                idlist: res.data
            });

        },
    },
})